﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:controls="clr-namespace:Corina.Controls.Win;assembly=Corina.Controls.Win">
    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="Brushes.xaml" />
        <ResourceDictionary Source="ButtonStyles.xaml" />
    </ResourceDictionary.MergedDictionaries>

    <Style TargetType="controls:PromptWindow">
        <Setter Property="HorizontalContentAlignment" Value="Center" />
        <Setter Property="OverlayBrush" Value="{StaticResource PageOverlayBrush}" />
        <Setter Property="OverlayOpacity" Value="1" />
        <Setter Property="HorizontalWindowAlignment" Value="Center" />
        <Setter Property="VerticalWindowAlignment" Value="Center" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="controls:PromptWindow">
                    <Grid x:Name="Root">
                        <Grid.Resources>
                            <Style x:Key="ButtonStyle" TargetType="Button">
                                <Setter Property="Background" Value="{StaticResource TransparentWhiteBrush}" />
                                <Setter Property="Foreground" Value="{StaticResource BlackColorBrush}" />
                                <Setter Property="Padding" Value="3" />
                                <Setter Property="BorderThickness" Value="1" />
                                <Setter Property="BorderBrush" Value="{StaticResource GrayBrush2}" />
                                <Setter Property="Template">
                                    <Setter.Value>
                                        <ControlTemplate TargetType="Button">
                                            <Grid x:Name="grid"
                                                  Width="15"
                                                  Height="14"
                                                  HorizontalAlignment="Center"
                                                  VerticalAlignment="Center"
                                                  Background="{StaticResource TransparentWhiteBrush}">
                                                <VisualStateManager.VisualStateGroups>
                                                    <VisualStateGroup x:Name="CommonStates">
                                                        <VisualState x:Name="Normal" />
                                                        <VisualState x:Name="MouseOver">
                                                            <Storyboard>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz2" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz1" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz0" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <DoubleAnimation Duration="0"
                                                                                 Storyboard.TargetName="X"
                                                                                 Storyboard.TargetProperty="Opacity"
                                                                                 To="0.95" />
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Pressed">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0"
                                                                                 Storyboard.TargetName="X"
                                                                                 Storyboard.TargetProperty="Opacity"
                                                                                 To="0.85" />
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz2" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz1" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                                                </ObjectAnimationUsingKeyFrames>
                                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="X_Fuzz0" Storyboard.TargetProperty="Visibility">
                                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="Visible" />
                                                                </ObjectAnimationUsingKeyFrames>
                                                            </Storyboard>
                                                        </VisualState>
                                                        <VisualState x:Name="Disabled">
                                                            <Storyboard>
                                                                <DoubleAnimation Duration="0"
                                                                                 Storyboard.TargetName="X"
                                                                                 Storyboard.TargetProperty="Opacity"
                                                                                 To="0.5" />
                                                            </Storyboard>
                                                        </VisualState>
                                                    </VisualStateGroup>
                                                </VisualStateManager.VisualStateGroups>
                                                <Path x:Name="X_Fuzz2"
                                                      Width="9"
                                                      Height="8"
                                                      Margin="0,-1,0,0"
                                                      HorizontalAlignment="Center"
                                                      VerticalAlignment="Center"
                                                      Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z"
                                                      Fill="{StaticResource FuzzBrush2}"
                                                      Opacity="1"
                                                      RenderTransformOrigin="0.5,0.5"
                                                      Stretch="Fill"
                                                      Stroke="{StaticResource FuzzBrush2}"
                                                      Visibility="Collapsed">
                                                    <Path.RenderTransform>
                                                        <TransformGroup>
                                                            <ScaleTransform ScaleX="1.3" ScaleY="1.3" />
                                                        </TransformGroup>
                                                    </Path.RenderTransform>
                                                </Path>
                                                <Path x:Name="X_Fuzz1"
                                                      Width="9"
                                                      Height="8"
                                                      Margin="0,-1,0,0"
                                                      HorizontalAlignment="Center"
                                                      VerticalAlignment="Center"
                                                      Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z"
                                                      Fill="{StaticResource FuzzBrush1}"
                                                      Opacity="1"
                                                      RenderTransformOrigin="0.5,0.5"
                                                      Stretch="Fill"
                                                      Stroke="{StaticResource FuzzBrush1}"
                                                      Visibility="Collapsed">
                                                    <Path.RenderTransform>
                                                        <TransformGroup>
                                                            <ScaleTransform ScaleX="1.1" ScaleY="1.1" />
                                                        </TransformGroup>
                                                    </Path.RenderTransform>
                                                </Path>
                                                <Path x:Name="X_Fuzz0"
                                                      Width="9"
                                                      Height="8"
                                                      Margin="0,-1,0,0"
                                                      HorizontalAlignment="Center"
                                                      VerticalAlignment="Center"
                                                      Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z"
                                                      Fill="{StaticResource FuzzBrush3}"
                                                      Opacity="1"
                                                      Stretch="Fill"
                                                      Stroke="{StaticResource FuzzBrush3}"
                                                      Visibility="Collapsed" />
                                                <Path x:Name="X"
                                                      Width="9"
                                                      Height="8"
                                                      Margin="0,-1,0,0"
                                                      HorizontalAlignment="Center"
                                                      VerticalAlignment="Center"
                                                      Data="F1 M 6.742676,3.852539 L 9.110840,1.559570 L 8.910645,0.500000 L 6.838379,0.500000 L 4.902832,2.435547 L 2.967285,0.500000 L 0.895020,0.500000 L 0.694824,1.559570 L 3.062988,3.852539 L 0.527832,6.351563 L 0.689941,7.600586 L 2.967285,7.600586 L 4.897949,5.575195 L 6.854004,7.600586 L 9.115723,7.600586 L 9.277832,6.351563 L 6.742676,3.852539 Z"
                                                      Fill="{StaticResource WhiteColorBrush}"
                                                      Opacity="0.7"
                                                      Stretch="Fill"
                                                      Stroke="{StaticResource GrayBrush3}" />
                                            </Grid>
                                        </ControlTemplate>
                                    </Setter.Value>
                                </Setter>
                            </Style>
                        </Grid.Resources>

                        <Border x:Name="Overlay"
                                Margin="0"
                                HorizontalAlignment="Stretch"
                                VerticalAlignment="Stretch"
                                Background="{TemplateBinding OverlayBrush}"
                                CornerRadius="5"
                                Opacity="{TemplateBinding OverlayOpacity}" />
                        <Grid x:Name="ContentRoot"
                              Width="{TemplateBinding WindowWidth}"
                              Height="{TemplateBinding WindowHeight}"
                              Margin="{TemplateBinding ContentMargin}"
                              HorizontalAlignment="{TemplateBinding HorizontalWindowAlignment}"
                              VerticalAlignment="{TemplateBinding VerticalWindowAlignment}"
                              RenderTransformOrigin="0.5,0.5">
                            <Grid.RenderTransform>
                                <TransformGroup>
                                    <ScaleTransform />
                                    <SkewTransform />
                                    <RotateTransform />
                                    <TranslateTransform />
                                </TransformGroup>
                            </Grid.RenderTransform>
                            <Border Background="{StaticResource WhiteColorBrush}"
                                    BorderBrush="{TemplateBinding BorderBrush}"
                                    Effect="{StaticResource DropShadowBrush}">
                                <Grid>
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="Auto" />
                                        <RowDefinition />
                                    </Grid.RowDefinitions>
                                    <Border x:Name="Chrome"
                                            Width="Auto"
                                            Background="Transparent"
                                            BorderThickness="0,0,0,1">
                                        <Grid Width="Auto" Height="Auto">
                                            <Grid.ColumnDefinitions>
                                                <ColumnDefinition />
                                                <ColumnDefinition Width="30" />
                                            </Grid.ColumnDefinitions>
                                            <ContentControl Margin="20,21,8,0"
                                                            HorizontalAlignment="Stretch"
                                                            VerticalAlignment="Center"
                                                            Content="{TemplateBinding Title}"
                                                            FontSize="18.667"
                                                            IsTabStop="False" />
                                            <Button x:Name="CloseButton"
                                                    Grid.Column="1"
                                                    HorizontalAlignment="Center"
                                                    VerticalAlignment="Top"
                                                    Command="{TemplateBinding CloseCommand}"
                                                    IsTabStop="False"
                                                    Style="{StaticResource style_button_close}" />
                                            <Rectangle Width="80"
                                                       Height="6"
                                                       Margin="20,15,0,0"
                                                       HorizontalAlignment="Left"
                                                       VerticalAlignment="Top"
                                                       Fill="{StaticResource BrandingBrush}" />
                                        </Grid>
                                    </Border>
                                    <Border Grid.Row="1"
                                            Margin="7"
                                            Background="{TemplateBinding Background}">
                                        <ContentPresenter x:Name="ContentPresenter"
                                                          HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                                          VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                                          Content="{TemplateBinding Content}"
                                                          ContentTemplate="{TemplateBinding ContentTemplate}" />
                                    </Border>
                                </Grid>
                            </Border>
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>